import { ResponseInterceptor } from './../../../interceptor/response/response.interceptor';
import { FocusService } from './../../../service/focus/focus.service';
import config from 'src/config/config';
import { Body, Controller, Delete, Get, Patch, Post, UseInterceptors } from '@nestjs/common';

@Controller(`${config.adminPath}/focus`)
@UseInterceptors(ResponseInterceptor)
export class FocusController {
    constructor(private readonly focusService: FocusService) {}
    @Get()
    async find() {
        return await this.focusService.find();
    }
    @Post()
    async create(@Body() body) {
        return await this.focusService.create(body);
    }
    @Patch()
    async update(@Body() body) {
        return await this.focusService.update(body);
    }
    @Delete()
    async delete(@Body() body) {
        return await this.focusService.delete(body);
    }
}
